package ucas.pin.web.controller;

import java.io.IOException;


import ucas.pin.web.services.ConsistCreate;
import ucas.pin.web.services.TreatCreate;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * @author Mark Angrish
 */
@RestController("/create")
public class CreateController {

	final ConsistCreate consistCreate;
	final TreatCreate treatCreate;
	

	@Autowired
	public CreateController(ConsistCreate consistCreate,TreatCreate treatCreate) {
		this.consistCreate = consistCreate;
		this.treatCreate = treatCreate;
	}
	
	
	

	@RequestMapping("/create/consist")
	public void createConsist() throws IOException {
		consistCreate.create_consist();
	}
	@RequestMapping("/create/treat")
	public void createTreate() throws IOException {
		treatCreate.create_treat();
		
	}
}
